home *** CD-ROM | disk | FTP | other *** search
/ Freaks Macintosh Archive / Freaks Macintosh Archive.bin / Freaks Macintosh Archives / Network / NetworkSecurityGuard.sit / NetworkSecurityGuard / NSG - applescript samples.rsrc / TEXT_1128.txt < prev    next >
Text File  |  1995-11-19  |  2KB  |  13 lines

  1. This is a sample AppleScript file which shows the syntax for controlling Network Security Guard via AppleScript. I know it's not pretty, but it works fine and dandy. There are several AppleScript (really AppleEvent) commands that NSG understands. One to trigger a network security check, one to set the zones which will be checked, one to provide NSG with a list of usernames/password combinations to use during a check, one to provide NSG with a list of usernames to try and one to provide NSG with a list of passwords to try. You may wonder why there are 3 related commands. Because NSG allows you to provide usernames and matching passwords to try (OR) provide separate usernames and passwords in which case it will try EACH combination of username and password that is possible. Understand? 
  2.  
  3.  An example of each is below. They've been tested and seem to work well. One final note: The "scan" command will queue a scan which will *NOT* start immediately. This is intentional. Otherwise, any script you write to start a scan would halt at that time until the scan was completed which could be a *long* time. 
  4. The syntax for the commands is as follows:
  5. aecommand "name_of_command, list,of,variables,goes,here,if,needed"
  6. name of command can be:
  7.      scan - which will trigger a network check (no list of variables required)
  8.      setzones - sets the list of zones to be scanned
  9.      setunpw - sets a list of username and passwords to be checked
  10.      setpassword - sets a list of passwords to be checked (empty = erased)
  11.      setusername - sets a list of usernames to be checked (empty = erased)
  12.      
  13. Also, NSG will attempt to send an AppleEvent to the application which requested a scan with the results of the password crack report. This AppleEvent will be of type nsg3rslt and will be an exact copy of the Password Crack report.